<template>
    <div class="new">
        <div class="headerr">
            <span class="shouye" @click="$router.push('/proportal/index')">首页 /</span>
            <span>发起绩效考核</span>
        </div>
        <div class="xuan">
            <div class="top">
                <span>填写考核内容</span>
            </div>
            <div class="bottom">绩效考核_填写指标</div>
        </div>
        <div class="table">
            <el-form :model="ruleForm" :rules="rules" ref="ruleForm" label-width="100px" label-position="top" class="demo-ruleForm">
                <el-form-item label="绩效考核周期" prop="range">
                    <el-date-picker
                        v-model="ruleForm.range"
                        type="daterange"
                        size="small"
                        value-format="yyyy-MM-dd"
                        range-separator="至"
                        start-placeholder="开始日期"
                        end-placeholder="结束日期">
                    </el-date-picker>
                </el-form-item>
                <el-form-item label="被考核人" prop="name">
                    <el-input v-model="ruleForm.name" size="small"></el-input>
                </el-form-item>
                <el-form-item label="被考核人部门" prop="department">
                    <el-input v-model="ruleForm.department" size="small" suffix-icon="el-icon-search"></el-input>
                </el-form-item>
            </el-form>
            <el-table
                ref="multipleTable"
                :data="tableData"
                border
                tooltip-effect="dark"
                style="width: 100%">
                <el-table-column
                    type="selection"
                    width="55">
                </el-table-column>
                <el-table-column label="权重"></el-table-column>
                <el-table-column label="内容"></el-table-column>
            </el-table>
            <el-pagination
                @size-change="handleSizeChange"
                @current-change="handleCurrentChange"
                :page-sizes="[10, 20, 50, 100]"
                :current-page.sync="pageInfo.page"
                :page-size="pageInfo.page_size"
                layout="total, sizes, prev, pager, next"
                :total="pageInfo.total"
                style="margin-bottom: 10px; margin-top: 10px"
            >
            </el-pagination>
        </div>
    </div>
</template>
<script>
export default{
    name:'new',
    data() {
        return {
            tableData:[],
            pageInfo: {
                page: 1,
                page_size: 20,
                total: 20,
                page_sizes: [10, 20, 30, 50],
            },
            ruleForm:{},
            rules:{
                range:[{required: true, message:'请输入', trigger: 'change'}],
                name:[{required: true, message:'请输入', trigger: 'blur'}],
                department:[{required: true, message:'请输入', trigger: 'blur'}]
            },
        }
    },
    methods:{
        handleCurrentChange(current) {
            this.pageInfo.page = current;
        },
        handleSizeChange(val) {
            this.pageInfo.page_size = val;
        },
    }
}
</script>
<style lang="less" scoped>
.new{
    width: 100%;
    .headerr{
        font-size: 14px;
        .shouye{
            color: rgba(0, 0, 0, 0.45);
            cursor: pointer;
            margin-right: 6px;
        }
    }
    .xuan{
        margin: 16px 0;
        padding: 24px;
        width: 100%;
        background-color: #fff;
        border-radius: 8px;
        .top{
            font-size: 18px;
            font-weight: 600;
            line-height: 25px;
        }
        .bottom{
            font-size: 14px;
            font-weight: 400;
            margin-top: 6px;
            line-height: 25px;
        }
    }
    .table{
        margin-top: 16px;
        padding: 24px 24px 14px;
        background-color: #fff;
        .el-form {
            display: flex;
            .el-form-item{
                flex: 1;
                margin: 0 10px 22px;
            }
        }
        .el-pagination{
            text-align: right;
        }
    }
}
</style>